﻿/*
 * 
 * Modify:
 *  2023/3/3 添加排序的封装
 * 
 * **/
namespace Max.PH5_2008A.ShoppingCode.IService
{
    public interface IBaseService<T> where T : class,new()
    {
        bool Insert(T t);
        bool Update(T t);
        bool Delete(List<T> ts);
        IQueryable<T> Query();
        IQueryable<T> Query(int pageIndex,int pageSize,out int count);
        IQueryable<T> Query<TKey>(int pageIndex, int pageSize, Func<T, TKey> sortFunc, bool sortIsDesc, out int count);
        IQueryable<T> Query(string where,int pageIndex, int pageSize,out int count);
        T QueryFirstById(string id);

    }
}